import {readFile} from 'fs'
//读取文件是异步的
export default (route)=>new Promise((resolve, reject) => {
     readFile(route,(err,data)=>{
        if(err){
            reject(err)
        }else{
            resolve(data)
            console.log(data);
        }
    })
})